package com.asa.rippleanimationview

import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import com.asa.rippleanimationview.ui.UIUtils

class MainActivity : AppCompatActivity() {


    private val binding : com.asa.rippleanimationview.databinding.ActivityMainBinding by lazy { com.asa.rippleanimationview.databinding.ActivityMainBinding.inflate(layoutInflater) }

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        UIUtils.getInstance(this)
        setContentView(binding.root)

        binding.music.setOnClickListener {
            if (binding.rippleAnimation.isRunning()){
                binding.rippleAnimation.stopAnimRunning()
            } else{
                binding.rippleAnimation.startAnimRunning()
            }
        }
    }
}